<?php
/**
 * Created by PhpStorm.
 * User: m3lon3ly
 * Date: 2018/3/9
 * Time: 下午4:46
 */

include_once 'config.php';  //  加载数据库配置文件

$sql = "insert into users (nickname,openid,icon,addtime,num) values ('testname','123123123','dasda','1520585626','1')";
if (mysqli_query($link, $sql)) {
    // 这里写逻辑
    include 'partition.php';
    echo "新记录插入成功";
} else {
    echo "Error: " . $sql . "<br>" . mysqli_error($conn);
}